package org.darkbits.cyklon.machine;

public abstract class AbstractOrderedProperty implements Comparable<AbstractOrderedProperty>, Property {
	
	public abstract int getOrder();
	
	public int compareTo(AbstractOrderedProperty o) {
		if (getOrder() == o.getOrder()) {
			return getName().compareTo(o.getName());
		}
		return getOrder() - o.getOrder();
	}
}